# include <bits/stdc++.h>
using namespace std;

int f[40][1000], n;

int main() { 
    freopen("subsetz.in","r",stdin);
    freopen("subsetz.out","w",stdout);
    scanf("%d", &n);
    f[1][1] = 1;
    for(int i = 2; i <= n; i++) { 
        int temp = (i * (i + 1)) >> 1;
        for(int j = 0; j <= temp; j++) { 
            f[i][j + i] += f[i - 1][j];
            f[i][abs(j - i)] += f[i - 1][j];
        }
    }
    printf("%d\n", f[n][0]);
}
